Skip to content

home page and assessment page#10

Open
jindoridodi wants to merge 5 commits intodevfrom
brian/frontend-setup
Open

home page and assessment page#10
jindoridodi wants to merge 5 commits intodevfrom
brian/frontend-setup

Conversation

@jindoridodi
Copy link
Copy Markdown
Collaborator

#2
Still have not set up the dockerfile yet tho

Copy link
Copy Markdown
Contributor

@adarshm11 adarshm11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good so far, you can proceed with dockerfile when ready

Comment thread Dockerfile.dev Outdated

COPY frontend/ .

CMD ["npm", "run", "dev", "--", "--host", "0.0.0.0", "--port", "7777"]
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this also be 6767 since 6767 is exposed in the backend portion?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

6767 is the backend port, so this will need to be a different port, we can go with 6766

Copy link
Copy Markdown
Contributor

@adarshm11 adarshm11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oof there are some naming/organizational conflicts here. the Dockerfiles for frontend and backend should be separated and placed next to the code they run, so let's do this:

  • move the frontend content from Dockerfile to a new file frontend/Dockerfile
  • move the frontend content from Dockerfile.dev to a new file frontend/Dockerfile.dev
  • for Dockerfile.dev (which now only contains the dev setup for the backend), look up the "air" dev tool. this will allow us to run the Go backend in dev mode with hot reloading (i.e. when we make a change, the code automatically updates rather than requiring the container to be restarted manually). this will also require a .air.toml file in the project root. feel free to use ai to assist you on this
  • update references for the Dockerfile context in docker-compose.dev.yml and docker-compose.yml!! and make sure to test running it all before you're done

Comment thread Dockerfile.dev Outdated

COPY frontend/ .

CMD ["npm", "run", "dev", "--", "--host", "0.0.0.0", "--port", "7777"]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

6767 is the backend port, so this will need to be a different port, we can go with 6766

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants